Skip to content

Type QuerySet.__class_getitem__ as returning the class - #3787

Merged
UnknownPlatypus merged 1 commit into
typeddjango:masterfrom
UnknownPlatypus:queryset-class-getitem-returns-class
Nov 5, 2026
Merged

UnknownPlatypus merged 1 commit into
typeddjango:masterfrom
UnknownPlatypus:queryset-class-getitem-returns-class

Conversation

@UnknownPlatypus

Copy link
Copy Markdown
Contributor

At runtime QuerySet.__class_getitem__ returns cls, but the stub returned an instance. Same signature as BaseManager.__class_getitem__.

Ported from sbdchd#412

AI Policy

  • I have read and agree to the AI Policy, removed any "Co-Authored-By" lines attributing coding agents, and manually reviewed the final result

At runtime `QuerySet.__class_getitem__` returns `cls`, but the stub returned an instance. Same signature as `BaseManager.__class_getitem__`.

Ported from sbdchd#412
@UnknownPlatypus
UnknownPlatypus merged commit a68b1f1 into typeddjango:master Nov 5, 2026
37 of 38 checks passed
@UnknownPlatypus
UnknownPlatypus deleted the queryset-class-getitem-returns-class branch November 5, 2026 21:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants